<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:f="http://java.sun.com/jsf/core" xmlns:h="http://java.sun.com/jsf/html">

<h:head>
	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
	<title>PetStore UOC - Practical Case</title>
</h:head>

<h:body>
 <font face="geneva,verdana,arial" size="2">
 <div id="layout">
	<div id="top" class="top">
		<ui:insert name="top">
			<table width="100%" cellspacing="0" border="0"
			  background="#{resource['images:bkg-topbar.gif']}">
			  <tr>
			    <td width="26"><img border="0" src="#{resource['images:petstore.gif']}"/></td>  
			  </tr>
			</table>
			<f:view>				
			 <h:form>
				<p>
					<td align="right"><b>Customer NIF:</b></td>
					<td align="right"><input type="text" maxlength="9" name="idCustomer" size="10"  style="text-align:right" /> 
						<h:commandButton value="Total Amount" immediate="true" action="#{totalAmount.ListTotalAmountOrders}">
							<f:param name="idCustomer" value="idCustomer"></f:param>
						</h:commandButton>
						<h:commandButton value="Total Orders" immediate="true" action="#{totalOrders.ListTotalOrders}">
							<f:param n-ame="idCustomer" value="idCustomer"></f:param>
						</h:commandButton>
					</td> 
				</p>
				<p>
				<td align="right"><b>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Order Id:</b></td>
					<td align="left"><input type="text" maxlength="9" name="idOrder" size="10"  style="text-align:right" /> 
						<h:commandButton value="&nbsp;&nbsp;&nbsp;List  Order&nbsp;&nbsp;&nbsp;" immediate="true" action="#{findorder.ListOrder}">
							<f:param name="idOrder" value="idOrder"></f:param>
						</h:commandButton>
						</td>
				</p>
				
					&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<h:commandButton align="left" value="&nbsp;List   Orders&nbsp;" immediate="true" renderer="#customer.administrator" action="#{listOrders.ListOrders}">
					
					</h:commandButton>
					<p>
					&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<h:commandButton align="left" value="New   Orders&nbsp;" immediate="true" action="#{testOrder.NewOrder}">
										</h:commandButton>
					
					</p>
			 </h:form>			
			</f:view>
		</ui:insert>
	</div>	
	<div id="content">
		<ui:insert name="content">
		
		</ui:insert>
	</div>
 </div>
</font>
</h:body>
</html>

